/**
 * Copyright 2019 bejson.com
 */
package io.nutz.nutzsite.common.weixin.bean;

import io.nutz.nutzsite.module.wx.models.WxUser;

import java.util.List;

/**
 * 微信公众 用户信息
 * https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140839
 */
public class User_info_list {

    /**
     * 用户是否订阅该公众号标识，值为0时，代表此用户没有关注该公众号，拉取不到其余信息。
     */
    private int subscribe;
    private String openid;
    private String nickname;
    private int sex;
    private String language;
    private String city;
    private String province;
    private String country;
    private String headimgurl;
    private long subscribe_time;
    private String remark;
    private int groupid;
    private List<String> tagid_list;
    private String subscribe_scene;
    private int qr_scene;
    private String qr_scene_str;

    public static WxUser getUser(User_info_list u){
        WxUser user =new WxUser();
        user.setSubscribe(u.getSubscribe());
        user.setOpenid(u.getOpenid());
        user.setNickname(u.getNickname());
        user.setSex(u.getSex());
        user.setCity(u.getCity());
        user.setProvince(u.getProvince());
        user.setCountry(u.getCountry());
        user.setHeadimgurl(u.getHeadimgurl());
        user.setSubscribeAt(u.getSubscribe_time());
        user.setRemark(u.getRemark());
        return user;
    }

    public int getSubscribe() {
        return subscribe;
    }

    public void setSubscribe(int subscribe) {
        this.subscribe = subscribe;
    }

    public String getOpenid() {
        return openid;
    }

    public void setOpenid(String openid) {
        this.openid = openid;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public int getSex() {
        return sex;
    }

    public void setSex(int sex) {
        this.sex = sex;
    }

    public String getLanguage() {
        return language;
    }

    public void setLanguage(String language) {
        this.language = language;
    }

    public String getCity() {
        return city;
    }

    public void setCity(String city) {
        this.city = city;
    }

    public String getProvince() {
        return province;
    }

    public void setProvince(String province) {
        this.province = province;
    }

    public String getCountry() {
        return country;
    }

    public void setCountry(String country) {
        this.country = country;
    }

    public String getHeadimgurl() {
        return headimgurl;
    }

    public void setHeadimgurl(String headimgurl) {
        this.headimgurl = headimgurl;
    }

    public long getSubscribe_time() {
        return subscribe_time;
    }

    public void setSubscribe_time(long subscribe_time) {
        this.subscribe_time = subscribe_time;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public int getGroupid() {
        return groupid;
    }

    public void setGroupid(int groupid) {
        this.groupid = groupid;
    }

    public List<String> getTagid_list() {
        return tagid_list;
    }

    public void setTagid_list(List<String> tagid_list) {
        this.tagid_list = tagid_list;
    }

    public String getSubscribe_scene() {
        return subscribe_scene;
    }

    public void setSubscribe_scene(String subscribe_scene) {
        this.subscribe_scene = subscribe_scene;
    }

    public int getQr_scene() {
        return qr_scene;
    }

    public void setQr_scene(int qr_scene) {
        this.qr_scene = qr_scene;
    }

    public String getQr_scene_str() {
        return qr_scene_str;
    }

    public void setQr_scene_str(String qr_scene_str) {
        this.qr_scene_str = qr_scene_str;
    }
}